package com.j180.servlet;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.function.DoublePredicate;

@WebServlet("/testParm")
public class TestPramServlet extends HttpServlet {

    @Override
    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {

        this.doPost(req,resp);
    }

    @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {

        System.out.println("TestPramServlet====>>>");
          //凡是从客户端过来发的参数都是字符串 文件（二进制）除外
        //获得请求的参数
        String  username = req.getParameter("username");
        String  pwd = req.getParameter("pwd");
    }
}
